// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
var qs = require('qs');

//引入公共方法
import Comment from './assets/js/public.js'
Vue.use(Comment)

//引入公共样式
import './assets/css/public.css'
//引入字体文件样式
import 'font-awesome/css/font-awesome.css'

//引入全局的 axios
import axios from 'axios';
axios.defaults.headers.post['Content-type'] = 'text/plain'
Vue.prototype.$axios = axios;
Vue.prototype.comment = Comment;

Vue.config.productionTip = false

//Mint ui 的部分
import 'mint-ui/lib/style.css'
import { Loadmore } from 'mint-ui';
Vue.component(Loadmore.name, Loadmore);

import { Spinner } from 'mint-ui';
Vue.component(Spinner.name, Spinner);

import { Button } from 'mint-ui';
Vue.component(Button.name, Button);

//museUi全部引入
import MuseUI from 'muse-ui';
import 'muse-ui/dist/muse-ui.css';
Vue.use(MuseUI);

import 'muse-ui-message/dist/muse-ui-message.css';
import Message from 'muse-ui-message';
Vue.use(Message);
import Toast from 'muse-ui-toast';
Toast.config({position:'top-start',closeIcon:'close'});
Vue.use(Toast);

//定义ajax请求全局变量

import {yesS,urlType} from './assets/js/http'
Vue.prototype.yesS=yesS;
Vue.prototype.urlType = urlType;

//懒加载
import lazyload from "vue-lazyload"
Vue.use(lazyload);

new Vue({
  el: '#app',
  router,
  components: { App },
  template: '<App/>',

})
